# Contributor: Michał Polański <michal@polanski.me>
# Maintainer: Michał Polański <michal@polanski.me>
pkgname=psi-notify
pkgver=1.3.1
pkgrel=0
pkgdesc="Notifier for system-wide resource pressure using PSI"
url="https://github.com/cdown/psi-notify"
license="MIT"
arch="all"
makedepends="libnotify-dev"
source="https://github.com/cdown/psi-notify/archive/$pkgver/psi-notify-$pkgver.tar.gz"

build() {
	make
}

check() {
	if [ -d /proc/pressure ]; then
		make test
	else
		echo "Skipping tests: no pressure directory found"
	fi
}

package() {
	install -Dm755 psi-notify "$pkgdir"/usr/bin/psi-notify
}

sha512sums="
bfc61e212097af53e6afdb916996418c7d05550a6bdf799f461da8d44bd2215e4a6a8d91b421b9c24326cf0d64e3a9e00fb8de87fb3aed4d1aa6018f289f62e8  psi-notify-1.3.1.tar.gz
"
